const path = require('path')
const htmlwebpackplugin = require('html-webpack-plugin')
const autossh = require('../src/main')

module.exports = {
	mode: 'development',
	entry: path.resolve(__dirname, './src/main.js'),
	output: {
		filename: '[name].js',
		path: path.resolve(__dirname, './build'),
		clean: true
	},
	module: {
		rules: [
			{
				test: /\.js$/,
				use: [
					'babel-loader'
				]
			},
		]
	},
	plugins: [
		new htmlwebpackplugin({
			template: path.resolve(__dirname, './index.html')
		}),
		new autossh({
			host: '10.190.55.173',
			username: 'root',
			password: 'password',
			remotePath: '/home/xiaoju/app/bigModal'
		})
	]
}